package com.haitrinh.NativeMediaPicker
{
	import flash.events.Event;
	
	public class NativeMediaPickerEvent extends Event
	{
		public static const MEDIA_PICKER_PICKED :String = "MEDIA_PICKER_EVENT_PICKED";
		public static const MEDIA_PICKER_CANCELLED :String = "MEDIA_PICKER_EVENT_CANCELLED";
		public static const MEDIA_PICKER_EVENT_UPDATE_PLAYBACK_TIME :String = "MEDIA_PICKER_EVENT_UPDATE_PLAYBACK_TIME";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_PLAYING :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_PLAYING";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_PAUSED :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_PAUSED";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_STOPPED :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_STOPPED";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_INTERRUPED :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_INTERRUPED";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_SEEKING_BACKWARD :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_SEEKING_BACKWARD";
		public static const MEDIA_PICKER_EVENT_PLAYBACK_STATE_SEEKING_FORWARD :String = "MEDIA_PICKER_EVENT_PLAYBACK_STATE_SEEKING_FORWARD";

		
		private var _pickedResult : String;
		
		public function NativeMediaPickerEvent(type:String, resultType:String = '', bubbles:Boolean=false, cancelable:Boolean=false)
		{
			if (resultType != '')
				_pickedResult = resultType;
			
			super(type, bubbles, cancelable);
		}
		
		public function get pickedResult():String
		{
			return _pickedResult;
		}
		
		public function set pickedResult(value:String):void
		{
			_pickedResult = value;
		}
	}
}